<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">

<title>module Minitest::Expectations - minitest: Ruby Standard Library Documentation</title>


<script src="../js/navigation.js" defer></script>
<script src="../js/search.js" defer></script>
<script src="../js/search_index.js" defer></script>
<script src="../js/searcher.js" defer></script>
<script src="../js/darkfish.js" defer></script>

<script src="../js/jquery-3.2.0.min.js"></script>

<script src="../js/vue.min.js"></script>
<script src="../js/js.cookie.min.js"></script>

<link href="../css/fonts.css" rel="stylesheet">
<link id='rdoccss' href="../css/rdoc.css" rel="stylesheet">
<link href="../css/carbon17.css" rel="stylesheet">

<script type="text/javascript">
  var rdoc_rel_prefix = "../";
  var index_rel_prefix = "../";
  var darkModeCsseHref = "../css/rdoc-dm.css"
  var defaultModeCssHref = "../css/rdoc.css"
  // var cssDarkmode = Cookies.get('darkmode');
  
  if( Cookies.get("darkmode") == "true") {
	$('#rdoccss').attr("href", darkModeCsseHref);
}

//  https://cssdeck.com/blog/simple-jquery-stylesheet-switcher/

document.write('<style type="text/css">body{display:none}</style>');

</script>


</head>
<body id="top" role="document" class="module">
  <!-- this is class.html -->

  <div id='actionbar' >
    <div class='wrapper mdiv'>
      <ul class='grids g0'></ul>
    </div> 
    <!-- VERSION HEADER for 3.3.0.preview2 NOT FOUND -->
  </div> <!-- end action bar -->

  <div class='wrapper hdiv'>

    


    <nav id='vapp' role="navigation">
    <div id="project-navigation">
      <div id="home-section" role="region" title="Quick navigation" class="nav-section">
  <h2><a href="../index.html" rel="home">Home</a></h2>

  <div id="table-of-contents-navigation"  >
    <a href="../table_of_contents.html#pages">Pages</a>
    <a href="../table_of_contents.html#classes">Classes</a>
    <a href="../table_of_contents.html#methods">Methods</a>
  </div>
</div>

      <div id="search-section" role="search" class="project-section initially-hidden">
  <form action="#" method="get" accept-charset="utf-8">
    <div id="search-field-wrapper">
      <input id="search-field" role="combobox" aria-label="Search"
             aria-autocomplete="list" aria-controls="search-results"
             type="text" name="search" placeholder="Search" spellcheck="false"
             title="Type to search, Up and Down to navigate, Enter to load">
    </div>

    <ul id="search-results" aria-label="Search Results"
        aria-busy="false" aria-expanded="false"
        aria-atomic="false" class="initially-hidden"></ul>
  </form>
</div>

    </div>


    

    <button id='toggleThing' @click="toggleNav()" >Show/hide navigation</button>
    <div :class="isOpen ? 'block' : 'hidden' " id='toggleMe'>
      <div id="class-metadata">
        
        
        
        
        
<!-- Method Quickref -->
<div id="method-list-section" class="nav-section">
  <h3>Methods</h3>

  <ul class="link-list" role="directory">
    <li ><a href="#method-i-must_be">#must_be</a>
    <li ><a href="#method-i-must_be_close_to">#must_be_close_to</a>
    <li ><a href="#method-i-must_be_empty">#must_be_empty</a>
    <li ><a href="#method-i-must_be_instance_of">#must_be_instance_of</a>
    <li ><a href="#method-i-must_be_kind_of">#must_be_kind_of</a>
    <li ><a href="#method-i-must_be_nil">#must_be_nil</a>
    <li ><a href="#method-i-must_be_same_as">#must_be_same_as</a>
    <li ><a href="#method-i-must_be_silent">#must_be_silent</a>
    <li ><a href="#method-i-must_be_within_epsilon">#must_be_within_epsilon</a>
    <li ><a href="#method-i-must_equal">#must_equal</a>
    <li ><a href="#method-i-must_include">#must_include</a>
    <li ><a href="#method-i-must_match">#must_match</a>
    <li ><a href="#method-i-must_output">#must_output</a>
    <li ><a href="#method-i-must_pattern_match">#must_pattern_match</a>
    <li ><a href="#method-i-must_raise">#must_raise</a>
    <li ><a href="#method-i-must_respond_to">#must_respond_to</a>
    <li ><a href="#method-i-must_throw">#must_throw</a>
    <li ><a href="#method-i-path_must_exist">#path_must_exist</a>
    <li ><a href="#method-i-path_wont_exist">#path_wont_exist</a>
    <li ><a href="#method-i-wont_be">#wont_be</a>
    <li ><a href="#method-i-wont_be_close_to">#wont_be_close_to</a>
    <li ><a href="#method-i-wont_be_empty">#wont_be_empty</a>
    <li ><a href="#method-i-wont_be_instance_of">#wont_be_instance_of</a>
    <li ><a href="#method-i-wont_be_kind_of">#wont_be_kind_of</a>
    <li ><a href="#method-i-wont_be_nil">#wont_be_nil</a>
    <li ><a href="#method-i-wont_be_same_as">#wont_be_same_as</a>
    <li ><a href="#method-i-wont_be_within_epsilon">#wont_be_within_epsilon</a>
    <li ><a href="#method-i-wont_equal">#wont_equal</a>
    <li ><a href="#method-i-wont_include">#wont_include</a>
    <li ><a href="#method-i-wont_match">#wont_match</a>
    <li ><a href="#method-i-wont_pattern_match">#wont_pattern_match</a>
    <li ><a href="#method-i-wont_respond_to">#wont_respond_to</a>
  </ul>
</div>

      </div>
     </div>
    </nav>


    <div id='extraz'><div class='adzbox-index'  >
      
     </div>         
    </div>

    <main role="main" aria-labelledby="module-Minitest::Expectations">
    <h1 id="module-Minitest::Expectations" class="module">
      module Minitest::Expectations
    </h1>

    <section class="description">
    
<p>It’s where you hide your “assertions”.</p>

<p>Please note, because of the way that expectations are implemented, all expectations (eg <a href="Expectations.html#method-i-must_equal"><code>must_equal</code></a>) are dependent upon a thread local variable <code>:current_spec</code>. If your specs rely on mixing threads into the specs themselves, you’re better off using assertions or the new _(value) wrapper. For example:</p>

<pre class="ruby"><span class="ruby-identifier">it</span> <span class="ruby-string">&quot;should still work in threads&quot;</span> <span class="ruby-keyword">do</span>
  <span class="ruby-identifier">my_threaded_thingy</span> <span class="ruby-keyword">do</span>
    (<span class="ruby-value">1</span><span class="ruby-value">+1</span>).<span class="ruby-identifier">must_equal</span> <span class="ruby-value">2</span>                  <span class="ruby-comment"># bad</span>
    <span class="ruby-identifier">assert_equal</span> <span class="ruby-value">2</span>, <span class="ruby-value">1</span><span class="ruby-value">+1</span>                 <span class="ruby-comment"># good</span>
    <span class="ruby-identifier">_</span>(<span class="ruby-value">1</span> <span class="ruby-operator">+</span> <span class="ruby-value">1</span>).<span class="ruby-identifier">must_equal</span> <span class="ruby-value">2</span>               <span class="ruby-comment"># good</span>
    <span class="ruby-identifier">value</span>(<span class="ruby-value">1</span> <span class="ruby-operator">+</span> <span class="ruby-value">1</span>).<span class="ruby-identifier">must_equal</span> <span class="ruby-value">2</span>           <span class="ruby-comment"># good, also #expect</span>
    <span class="ruby-identifier">_</span> { <span class="ruby-value">1</span> <span class="ruby-operator">+</span> <span class="ruby-string">&quot;1&quot;</span> }.<span class="ruby-identifier">must_raise</span> <span class="ruby-constant">TypeError</span>  <span class="ruby-comment"># good</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span>
</pre>

    </section>

      <section id="5Buntitled-5D" class="documentation-section">





                <section id="public-instance-5Buntitled-5D-method-details" class="method-section">
                <header>
                <h3>Public Instance Methods</h3>
                </header>

                  <div id="method-i-must_be" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_be</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_operator"><code>Minitest::Assertions#assert_operator</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">n</span>).<span class="ruby-identifier">must_be</span> <span class="ruby-value">:&lt;=</span>, <span class="ruby-value">42</span>
</pre>

<p>This can also do predicates:</p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">str</span>).<span class="ruby-identifier">must_be</span> <span class="ruby-value">:empty?</span>
</pre>

                              <div class="method-source-code" id="must_be-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 116</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_operator</span>, <span class="ruby-value">:must_be</span>, <span class="ruby-value">:reverse</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_be_close_to" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_be_close_to</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_in_delta"><code>Minitest::Assertions#assert_in_delta</code></a></p>

<pre>_(n).must_be_close_to m [, delta]</pre>

                              <div class="method-source-code" id="must_be_close_to-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 47</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_in_delta</span>, <span class="ruby-value">:must_be_close_to</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_be_empty" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_be_empty</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_empty"><code>Minitest::Assertions#assert_empty</code></a>.</p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">collection</span>).<span class="ruby-identifier">must_be_empty</span>
</pre>

                              <div class="method-source-code" id="must_be_empty-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 29</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_empty</span>, <span class="ruby-value">:must_be_empty</span>, <span class="ruby-value">:unary</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_be_instance_of" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_be_instance_of</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_instance_of"><code>Minitest::Assertions#assert_instance_of</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">obj</span>).<span class="ruby-identifier">must_be_instance_of</span> <span class="ruby-identifier">klass</span>
</pre>

                              <div class="method-source-code" id="must_be_instance_of-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 76</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_instance_of</span>, <span class="ruby-value">:must_be_instance_of</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_be_kind_of" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_be_kind_of</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_kind_of"><code>Minitest::Assertions#assert_kind_of</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">obj</span>).<span class="ruby-identifier">must_be_kind_of</span> <span class="ruby-identifier">mod</span>
</pre>

                              <div class="method-source-code" id="must_be_kind_of-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 85</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_kind_of</span>, <span class="ruby-value">:must_be_kind_of</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_be_nil" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_be_nil</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_nil"><code>Minitest::Assertions#assert_nil</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">obj</span>).<span class="ruby-identifier">must_be_nil</span>
</pre>

                              <div class="method-source-code" id="must_be_nil-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 103</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_nil</span>, <span class="ruby-value">:must_be_nil</span>, <span class="ruby-value">:unary</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_be_same_as" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_be_same_as</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_same"><code>Minitest::Assertions#assert_same</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">a</span>).<span class="ruby-identifier">must_be_same_as</span> <span class="ruby-identifier">b</span>
</pre>

                              <div class="method-source-code" id="must_be_same_as-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 161</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_same</span>, <span class="ruby-value">:must_be_same_as</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_be_silent" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_be_silent</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_silent"><code>Minitest::Assertions#assert_silent</code></a></p>

<pre>_ { ... }.must_be_silent</pre>

                              <div class="method-source-code" id="must_be_silent-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 170</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_silent</span>, <span class="ruby-value">:must_be_silent</span>, <span class="ruby-value">:block</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_be_within_epsilon" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_be_within_epsilon</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_in_epsilon"><code>Minitest::Assertions#assert_in_epsilon</code></a></p>

<pre>_(n).must_be_within_epsilon m [, epsilon]</pre>

                              <div class="method-source-code" id="must_be_within_epsilon-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 58</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_in_epsilon</span>, <span class="ruby-value">:must_be_within_epsilon</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_equal" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_equal</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_equal"><code>Minitest::Assertions#assert_equal</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">a</span>).<span class="ruby-identifier">must_equal</span> <span class="ruby-identifier">b</span>
</pre>

                              <div class="method-source-code" id="must_equal-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 38</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_equal</span>, <span class="ruby-value">:must_equal</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_include" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_include</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_includes"><code>Minitest::Assertions#assert_includes</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">collection</span>).<span class="ruby-identifier">must_include</span> <span class="ruby-identifier">obj</span>
</pre>

                              <div class="method-source-code" id="must_include-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 67</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_includes</span>, <span class="ruby-value">:must_include</span>, <span class="ruby-value">:reverse</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_match" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_match</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_match"><code>Minitest::Assertions#assert_match</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">a</span>).<span class="ruby-identifier">must_match</span> <span class="ruby-identifier">b</span>
</pre>

                              <div class="method-source-code" id="must_match-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 94</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_match</span>, <span class="ruby-value">:must_match</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_output" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_output</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_output"><code>Minitest::Assertions#assert_output</code></a></p>

<pre>_ { ... }.must_output out_or_nil [, err]</pre>

                              <div class="method-source-code" id="must_output-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 125</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_output</span>, <span class="ruby-value">:must_output</span>, <span class="ruby-value">:block</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_pattern_match" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_pattern_match</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See Minitest::Assertions#assert_pattern_match</p>

<pre>_ { ... }.must_pattern_match [...]</pre>

                              <div class="method-source-code" id="must_pattern_match-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 134</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_pattern</span>, <span class="ruby-value">:must_pattern_match</span>, <span class="ruby-value">:block</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_raise" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_raise</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_raises"><code>Minitest::Assertions#assert_raises</code></a></p>

<pre>_ { ... }.must_raise exception</pre>

                              <div class="method-source-code" id="must_raise-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 143</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_raises</span>, <span class="ruby-value">:must_raise</span>, <span class="ruby-value">:block</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_respond_to" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_respond_to</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_respond_to"><code>Minitest::Assertions#assert_respond_to</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">obj</span>).<span class="ruby-identifier">must_respond_to</span> <span class="ruby-identifier">msg</span>
</pre>

                              <div class="method-source-code" id="must_respond_to-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 152</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_respond_to</span>, <span class="ruby-value">:must_respond_to</span>, <span class="ruby-value">:reverse</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-must_throw" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">must_throw</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_throws"><code>Minitest::Assertions#assert_throws</code></a></p>

<pre>_ { ... }.must_throw sym</pre>

                              <div class="method-source-code" id="must_throw-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 179</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_throws</span>, <span class="ruby-value">:must_throw</span>, <span class="ruby-value">:block</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-path_must_exist" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">path_must_exist</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-assert_path_exists"><code>Minitest::Assertions#assert_path_exists</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">some_path</span>).<span class="ruby-identifier">path_must_exist</span>
</pre>

                              <div class="method-source-code" id="path_must_exist-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 188</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:assert_path_exists</span>, <span class="ruby-value">:path_must_exist</span>, <span class="ruby-value">:unary</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-path_wont_exist" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">path_wont_exist</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_path_exists"><code>Minitest::Assertions#refute_path_exists</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">some_path</span>).<span class="ruby-identifier">path_wont_exist</span>
</pre>

                              <div class="method-source-code" id="path_wont_exist-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 197</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_path_exists</span>, <span class="ruby-value">:path_wont_exist</span>, <span class="ruby-value">:unary</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_be" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_be</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_operator"><code>Minitest::Assertions#refute_operator</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">n</span>).<span class="ruby-identifier">wont_be</span> <span class="ruby-value">:&lt;=</span>, <span class="ruby-value">42</span>
</pre>

<p>This can also do predicates:</p>

<pre class="ruby"><span class="ruby-identifier">str</span>.<span class="ruby-identifier">wont_be</span> <span class="ruby-value">:empty?</span>
</pre>

                              <div class="method-source-code" id="wont_be-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 293</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_operator</span>, <span class="ruby-value">:wont_be</span>, <span class="ruby-value">:reverse</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_be_close_to" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_be_close_to</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_in_delta"><code>Minitest::Assertions#refute_in_delta</code></a></p>

<pre>_(n).wont_be_close_to m [, delta]</pre>

                              <div class="method-source-code" id="wont_be_close_to-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 224</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_in_delta</span>, <span class="ruby-value">:wont_be_close_to</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_be_empty" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_be_empty</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_empty"><code>Minitest::Assertions#refute_empty</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">collection</span>).<span class="ruby-identifier">wont_be_empty</span>
</pre>

                              <div class="method-source-code" id="wont_be_empty-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 206</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_empty</span>, <span class="ruby-value">:wont_be_empty</span>, <span class="ruby-value">:unary</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_be_instance_of" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_be_instance_of</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_instance_of"><code>Minitest::Assertions#refute_instance_of</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">obj</span>).<span class="ruby-identifier">wont_be_instance_of</span> <span class="ruby-identifier">klass</span>
</pre>

                              <div class="method-source-code" id="wont_be_instance_of-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 253</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_instance_of</span>, <span class="ruby-value">:wont_be_instance_of</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_be_kind_of" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_be_kind_of</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_kind_of"><code>Minitest::Assertions#refute_kind_of</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">obj</span>).<span class="ruby-identifier">wont_be_kind_of</span> <span class="ruby-identifier">mod</span>
</pre>

                              <div class="method-source-code" id="wont_be_kind_of-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 262</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_kind_of</span>, <span class="ruby-value">:wont_be_kind_of</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_be_nil" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_be_nil</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_nil"><code>Minitest::Assertions#refute_nil</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">obj</span>).<span class="ruby-identifier">wont_be_nil</span>
</pre>

                              <div class="method-source-code" id="wont_be_nil-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 280</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_nil</span>, <span class="ruby-value">:wont_be_nil</span>, <span class="ruby-value">:unary</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_be_same_as" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_be_same_as</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_same"><code>Minitest::Assertions#refute_same</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">a</span>).<span class="ruby-identifier">wont_be_same_as</span> <span class="ruby-identifier">b</span>
</pre>

                              <div class="method-source-code" id="wont_be_same_as-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 320</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_same</span>, <span class="ruby-value">:wont_be_same_as</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_be_within_epsilon" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_be_within_epsilon</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_in_epsilon"><code>Minitest::Assertions#refute_in_epsilon</code></a></p>

<pre>_(n).wont_be_within_epsilon m [, epsilon]</pre>

                              <div class="method-source-code" id="wont_be_within_epsilon-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 235</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_in_epsilon</span>, <span class="ruby-value">:wont_be_within_epsilon</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_equal" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_equal</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_equal"><code>Minitest::Assertions#refute_equal</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">a</span>).<span class="ruby-identifier">wont_equal</span> <span class="ruby-identifier">b</span>
</pre>

                              <div class="method-source-code" id="wont_equal-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 215</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_equal</span>, <span class="ruby-value">:wont_equal</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_include" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_include</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_includes"><code>Minitest::Assertions#refute_includes</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">collection</span>).<span class="ruby-identifier">wont_include</span> <span class="ruby-identifier">obj</span>
</pre>

                              <div class="method-source-code" id="wont_include-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 244</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_includes</span>, <span class="ruby-value">:wont_include</span>, <span class="ruby-value">:reverse</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_match" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_match</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_match"><code>Minitest::Assertions#refute_match</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">a</span>).<span class="ruby-identifier">wont_match</span> <span class="ruby-identifier">b</span>
</pre>

                              <div class="method-source-code" id="wont_match-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 271</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_match</span>, <span class="ruby-value">:wont_match</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_pattern_match" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_pattern_match</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See Minitest::Assertions#refute_pattern_match</p>

<pre>_ { ... }.wont_pattern_match [...]</pre>

                              <div class="method-source-code" id="wont_pattern_match-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 302</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_pattern</span>, <span class="ruby-value">:wont_pattern_match</span>, <span class="ruby-value">:block</span>
</pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-wont_respond_to" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">wont_respond_to</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>See <a href="Assertions.html#method-i-refute_respond_to"><code>Minitest::Assertions#refute_respond_to</code></a></p>

<pre class="ruby"><span class="ruby-identifier">_</span>(<span class="ruby-identifier">obj</span>).<span class="ruby-identifier">wont_respond_to</span> <span class="ruby-identifier">msg</span>
</pre>

                              <div class="method-source-code" id="wont_respond_to-source">
            <pre><span class="ruby-comment"># File minitest-5.20.0/lib/minitest/expectations.rb, line 311</span>
<span class="ruby-identifier">infect_an_assertion</span> <span class="ruby-value">:refute_respond_to</span>, <span class="ruby-value">:wont_respond_to</span>, <span class="ruby-value">:reverse</span>
</pre>
                              </div>
                            </div>


                          </div>

                          </section>

              </section>
              </main>



            </div>  <!--  class='wrapper hdiv' -->


<footer id="validator-badges" role="contentinfo">
<p><a href="https://validator.w3.org/check/referer">Validate</a></p>
<p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.4.0.</p>
<p>Based on <a href="https://github.com/ged/darkfish/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.</p>

  
    <p><p><a href="https://ruby-doc.org">Ruby-doc.org</a> is provided by <a href="https://jamesbritt.com">James Britt</a> and <a href="https://neurogami.com">Neurogami</a>.</p><p><a href="https://jamesbritt.bandcamp.com/">Maximum R+D</a>.  </p>
</p>
  
  </footer>

<script type="text/javascript">


  let ads  = $("#carbonads-container").children().detach();


  function swapMode() {
    var cookieName = 'darkmode';
    var cssDarkmode = Cookies.get(cookieName);
    console.log("***** swapMode! " + cssDarkmode + " *****");


    if (cssDarkmode == "true") {
      console.log("We have dark mode, set the css to light ...");
      $('#rdoccss').attr("href", defaultModeCssHref);
      $('#cssSelect').text("Dark mode");
      cssDarkmode = "false";
      console.log("swapMode! Now set cookie to " + cssDarkmode);
      Cookies.set(cookieName, cssDarkmode);

    } else {
      console.log("We not have dark mode, set the css to dark ...");
      $('#rdoccss').attr("href", darkModeCsseHref);
      $('#cssSelect').text("Light mode");
      cssDarkmode = "true";
      console.log("swapMode! Now set cookie to " + cssDarkmode);
      Cookies.set(cookieName, cssDarkmode);

    }

    console.log("  --------------- ");
  }


const vueCssApp = new Vue({
el: '#menubar',
data: {
isDark: false
},
methods: {
toggleClass: function(event){
this.isDark = !this.isDark;
}
}
})

const vueApp = new Vue({
el: '#vapp',
data: { 
isOpen: true
},

mounted() {
this.handleResize();
this.manage_mob_classes();
window.addEventListener('resize', this.handleResize)
//this.isOpen !=  (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent));
},
destroyed() {
window.removeEventListener('resize', this.handleResize)
},
created() {
//manage_mob_classes();
},

methods : {
isMobile() {
  return (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent));
},

  handleResize() {
    if (!this.isMobile()) {
      this.isOpen = window.innerWidth > 800;
    }
  },

  manage_mob_classes() {
    if (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)) {
      $("nav").addClass("mob_nav");
      $("main").addClass("mob_main");
      $("#extraz").addClass("mob_extraz");
      $("#carbonads-container").addClass("mob_carbonads-container");
      this.isOpen  = false;
    } else {
      $("nav").removeClass("mob_nav") 
        $("main").removeClass("mob_main");
      $("#extraz").removeClass("mob_extraz");
      $("#carbonads-container").removeClass("mob_carbonads-container");
      this.isOpen  = true;
    }
  },

  toggleNav() {
    this.isOpen =! this.isOpen ;
    // alert("Toggle nav!");
    console.log("toggleNav() click: " + this.isOpen );
  }
}
})

$("#carbonads-container").append(ads);


$(function() {

    var darkmode = Cookies.get("darkmode");
    console.log("Document ready: " + darkmode);

    if ( darkmode  == "true" ) {
      $('#cssSelect').text("Light mode");
    } else {
      $('#cssSelect').text("Dark mode");
     }

    $('body').css('display','block');
    });

</script>

    
  </body> 
</html>

